package cn.gson.oasys.services.mail.impl;

import cn.gson.oasys.model.dao.maildao.MailreciverDao;
import cn.gson.oasys.model.entity.mail.Mailreciver;
import cn.gson.oasys.model.entity.user.User;
import cn.gson.oasys.services.mail.MailServices;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.transaction.Transactional;
import java.util.List;

@Service
@Transactional
public class MailServicesImpl implements MailServices {

    @Autowired
    private MailreciverDao mrdao;

    //记日志
    Logger log = LoggerFactory.getLogger(getClass());

    //未读邮件查询
    @Override
    public List<Mailreciver> findByReadAndDelAndReciverId(boolean b, boolean b1, User user) {
        return mrdao.findByReadAndDelAndReciverId(b, b1, user);
    }

}
